#include<iostream>
#include<algorithm>
#include<string>
#include<vector>
#include<map>
#include<set>
#include<queue>
#include<list>
#include<cstdlib>
#include<cmath>
#include<sstream>
#include<numeric>
#include<cstdio>
#include<cstring>
#include<stack>
#define PI acos(-1)
#define MP make_pair
#define PB push_back
#define VI vector <int>
#define PII pair <int,int>
#define LL long long
#define SET(v,i) memset(v, i, sizeof(v))
#define FOR(i,a,b) for (int i = (a); i <= (b); i++)
#define FORD(i,a,b) for (int i = (a); i >= (b); i--)
#define FORN(i,a,b) for (int i = (a); i < (b); i++)
#define DOWN(i,a,b) for (int i = (a); i > (b); i--)
#define FIT(it,v) for (typeof(v.begin()) it = v.begin(); it != v.end(); it++)
#define FITD(it,v) for (typeof(v.rbegin()) it = v.rbegin(); it != v.rend(); it++)
using namespace std;
const int MAXN=301,MAXM=100001;
vector<pair<int,int> >v[MAXN];
LL dp[MAXN][MAXN],c[MAXN][MAXN];
inline LL MI(LL x,LL y){
	if(y==-1)return x;
	else if(x==-1)return y;
	else return min(x,y);
	}
int main(){
	int n,m,k,x,y,z;
	while(scanf("%d%d%d",&n,&m,&k)!=EOF){
		for(int i=0;i<=n;i++)for(int j=0;j<=n;j++)dp[i][j]=c[i][j]=-1;
		for(int i=1;i<=m;i++){
			scanf("%d%d%d",&x,&y,&z);
			for(int j=x;j<=y;j++)c[j][y]=MI(c[j][y],z);
			}
		
		dp[0][0]=0;
		for(int i=1;i<=n;i++){
			for(int j=i;j>=0;j--){
				dp[i][j]=MI(dp[i][j],dp[i-1][j]);
				if(j+1<=n)dp[i][j]=MI(dp[i][j],dp[i][j+1]);
				for(int k=i-j;k<i;k++)if(c[k+1][i]!=-1&&dp[k][j-i+k]!=-1)
				dp[i][j]=MI(dp[i][j],dp[k][j-i+k]+c[k+1][i]);
				}
			}	
		cout<<dp[n][k]<<endl;
		}
    return 0;
    }
